<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:simpleType name="boolean">
    <xs:restriction base="xs:boolean"/>
  </xs:simpleType>
  <xs:simpleType name="string">
    <xs:restriction base="xs:string"/>
  </xs:simpleType>
  <xs:complexType name="c_string">
    <xs:simpleContent>
      <xs:extension base="string"/>
    </xs:simpleContent>
  </xs:complexType>
  <xs:complexType name="subitem">
    <xs:complexContent>
      <xs:extension base="c_string">
        <xs:attribute name="checked" type="boolean" use="required"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType name="item" mixed="true">
    <xs:sequence minOccurs="0" maxOccurs="unbounded">
      <xs:element name="subitem" minOccurs="0">
        <xs:complexType>
          <xs:complexContent>
            <xs:extension base="subitem"/>
          </xs:complexContent>
        </xs:complexType>
      </xs:element>
    </xs:sequence>
    <xs:attribute name="lang" type="string" use="optional"/>
  </xs:complexType>
  <xs:complexType name="items">
    <xs:sequence>
      <xs:element name="item" minOccurs="0" maxOccurs="unbounded">
        <xs:complexType>
          <xs:complexContent>
            <xs:extension base="item"/>
          </xs:complexContent>
        </xs:complexType>
      </xs:element>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="listitems">
    <xs:sequence minOccurs="0">
      <xs:element name="listitem" maxOccurs="unbounded">
        <xs:complexType>
          <xs:sequence>
            <xs:element name="item" maxOccurs="unbounded">
              <xs:complexType>
                <xs:complexContent>
                  <xs:extension base="item"/>
                </xs:complexContent>
              </xs:complexType>
            </xs:element>
          </xs:sequence>
        </xs:complexType>
      </xs:element>
    </xs:sequence>
  </xs:complexType>
  <xs:element name="test">
    <xs:complexType>
      <xs:complexContent>
        <xs:extension base="listitems"/>
      </xs:complexContent>
    </xs:complexType>
  </xs:element>
</xs:schema>
